package barbershop.com.dao;

import barbershop.com.entity.Admin;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.Query;
import org.springframework.stereotype.Repository;

@Repository
public interface AdminDao extends JpaRepository<Admin, Integer> {
    @Query(value = "select * from admin where a_name=?1 and a_pwd=?2",
            nativeQuery = true)
    Admin aLogin(String aName, String aPwd);
}
